package qingke.blog.pojo;

import java.util.Date;

public class Article {
	
	private int id;
	private String articleName;
	private String contentPath;
	private Date date;
	private int userId;
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}

	public int getUserId() {
		return userId;
	}
	public void setUserId(int userId) {
		this.userId = userId;
	}
	public String getArticleName() {
		return articleName;
	}
	public void setArticleName(String articleName) {
		this.articleName = articleName;
	}
    
	public String getContentPath() {
		return contentPath;
	}
	public void setContentPath(String contentPath) {
		this.contentPath = contentPath;
	}
	public Date getDate() {
		return date;
	}
	public void setDate(Date date) {
		this.date = date;
	}
	
    public String getMonth(){
		int month=getDate().getMonth();
		switch (month) {
		case 0: 
			 return "Jan";
		case 1:
			 return "Feb";
		case 2:
			 return  "Mar";
		case 3:
			return  "Apr";
		case 4:
			return  "May";
		case 5:
			return  "Jun";
		case 6:
			return  "Jul";
		case 7:
			return  "Aug";
		case 8:
			return  "Sep";
		case 9:
			return  "Oct";
		case 10:
			return  "Nov";
		case 11:
			return  "Dec";
		default:
			return null;
		}
    }
}
